package com.wuxiaoqin.admin.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.wuxiaoqin.admin.entity.Commodity;
import com.wuxiaoqin.admin.entity.Goodsimg;
import com.wuxiaoqin.admin.entity.Goodsstock;
import com.wuxiaoqin.admin.entity.goodParam.GoodsAdd;
import com.wuxiaoqin.admin.entity.goodParam.GoodsAll;
import com.wuxiaoqin.admin.entity.goodParam.GoodsImgModify;
import com.wuxiaoqin.admin.entity.goodParam.GoodsSales;
import com.wuxiaoqin.uitls.respObj.RespBean;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author jobob
 * @since 2021-11-02
 */
public interface ICommodityService extends IService<Commodity> {



    RespBean selectClass();

    RespBean goodsAdd(MultipartFile file, GoodsAdd goodsAdd) throws IOException;

    Page<GoodsAll> getGoods(Integer pn, Integer size);

    Commodity getGoodsById(Integer id);

    RespBean deleteGoodById(Integer id);

    Goodsstock getGoodsStockById(Integer id);

    Goodsimg getGoodsImg(Integer id);

    RespBean modifyGoodsImg(Integer id, GoodsImgModify goodsImgModify) throws IOException;

    RespBean delGoodsImg(Integer id);

    Page<GoodsSales> salesVolume(Integer pn, Integer size);

}
